package com.oro.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;

import com.oro.dao.UserDao;
import com.oro.domain.User;
import com.oro.service.UserService;

public class UserServiceImpl implements UserService {
	
	@Autowired
	UserDao userDao;

	
	@Override
	public List<User> getAllUsers() {
		return userDao.getUsers();
	}

	@Override
	public User getUserByUsername(String username) {
		return userDao.getUserByUsername(username);
	}

	public UserDao getUserDao() {
		return userDao;
	}

	@Override
	public List<User> getUsers() {
		return userDao.getUsers();
	}

	@Override
	public void save(User user) {
		userDao.save(user);		
	}

	public void setUserDao(UserDao userDao) {
		this.userDao = userDao;
	}

}
